package com.appspot.didit.client.workitem;

import com.google.gwt.event.shared.GwtEvent;

public class WorkitemChangedEvent extends GwtEvent<WorkitemChangedHandler> {

    private static Type<WorkitemChangedHandler> TYPE;

    public int getRowCount() {
		return rowCount;
	}

	public void setRowCount(int rowCount) {
		this.rowCount = rowCount;
	}

	private int rowCount;
    
    public static Type<WorkitemChangedHandler> getType() {
            return TYPE != null ? TYPE
                            : (TYPE = new Type<WorkitemChangedHandler>());
    }

    public WorkitemChangedEvent(int rowCount) {
    	this.rowCount = rowCount;
    }

    @Override
    public final Type<WorkitemChangedHandler> getAssociatedType() {
            return getType();
    }

    @Override
    protected void dispatch(WorkitemChangedHandler handler) {
            handler.onWorkitemChanged(this);
    }

}